#include <iostream>
using namespace std;

int main()
{
    ios::sync_with_stdio(false);
    long long m[51] = {0}; //methods
    int n, i;
    m[1] = 1;
    m[2] = 2;
    m[3] = 3;
    for (i = 4; i < 51; i++)
    {
        m[i] = m[i - 1] + m[i - 2];
    }
    while (cin >> n)
    {
        cout << m[n] << endl;
    }
    return 0;
}